package com.itms.tool;

import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.EditText;

public class MainActivity extends BaseActivity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
		final EditText username = (EditText) findViewById(R.id.username);
		final EditText password = (EditText) findViewById(R.id.password);
		findViewById(R.id.login).setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				String unm = username.getText().toString();
				String pwd = password.getText().toString();
				if (isAuthentic(unm, pwd)) {
					startActivity(NewObjectActivity.class);
					finish();
				}
			}
		});
	}

	private boolean isAuthentic(String username, String password) {
		return true;
	}
	
}
